Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove --host-whitelist 2.0 #7884

Closed
wants to merge 7 commits into from

Conversation

JanetMo
Copy link

@JanetMo JanetMo commented Nov 17, 2024

remove the --host-whitelist option, issue #7761

deleted the command and it's associated tests, the changelog was already adapted

paramLabel = "<hostname>[,<hostname>...]... or * or all",
description =
"Deprecated in favor of --host-allowlist. Comma separated list of hostnames to allow for RPC access, or * to accept any host (default: ${DEFAULT-VALUE})")
private final JsonRPCAllowlistHostsProperty hostsWhitelist = new JsonRPCAllowlistHostsProperty();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is also some code in the configure method of BesuCommand that uses the hostsWhitelist variable that needs to be removed as well

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review! You mean this part further down in the same file, of another one?

    // hostsWhitelist is a hidden option. If it is specified, add the list to hostAllowlist
    if (!hostsWhitelist.isEmpty()) {
      // if allowlist == default values, remove the default values
      if (hostsAllowlist.size() == 2
          && hostsAllowlist.containsAll(List.of("localhost", "127.0.0.1"))) {
        hostsAllowlist.removeAll(List.of("localhost", "127.0.0.1"));
      }
      hostsAllowlist.addAll(hostsWhitelist);
    }

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JanetMo if you run ./gradlew compileJava you will see compile errors locally

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@macfarla Thanks, unfortunately we were still not able to run the repo locally... Could you guide us on which piece of code to remove?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JanetMo feel free to post in discord if you're having trouble compiling or building locally, plenty of folks there that can help you out

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@macfarla Thanks, appreciate the support. I retried but still wasn't able to build it locally, is there a way to unassign from the issue? I think I'm not up for it, and probably holding you back on with this one.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok yes I can unassign you @JanetMo - you're welcome back any time - but being able to compile the code is a must :)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@macfarla Thanks, I'm sorry it didn't work despite your help, learned something about Besu nevertheless 👍

@macfarla macfarla marked this pull request as draft November 19, 2024 06:16
Copy link
Contributor

@macfarla macfarla left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

needs a changelog entry since this is a breaking change

@@ -66,7 +66,6 @@ services:
- --rpc-ws-enabled
- --rpc-ws-apis=admin,eth,miner,web3,net,priv,eea
- --rpc-ws-host=0.0.0.0
- --host-whitelist=*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of deleting this line, can you change to host-allowlist

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alright, I changed it to host-allowlist

@@ -84,7 +83,6 @@ services:
- --rpc-ws-enabled
- --rpc-ws-apis=admin,eth,miner,web3,net,priv,eea
- --rpc-ws-host=0.0.0.0
- --host-whitelist=*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of deleting this line, can you change to host-allowlist

Copy link
Author

@JanetMo JanetMo Nov 30, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed as well, thanks for reviewing!

@macfarla macfarla self-assigned this Nov 27, 2024
@JanetMo
Copy link
Author

JanetMo commented Nov 30, 2024

@macfarla I think the changelog entry was already done in this PR #7762

@macfarla
Copy link
Contributor

macfarla commented Dec 2, 2024

@macfarla I think the changelog entry was already done in this PR #7762

that's an "Upcoming" breaking change.

still need to add it into the changelog for this release as a "Breaking" change for maximum signal to users

@macfarla
Copy link
Contributor

macfarla commented Dec 9, 2024

closing this PR at request of @JanetMo and it's now assigned to @pr9t

@macfarla macfarla closed this Dec 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants